package de.baumann.browser.present

import de.baumann.browser.api.OdinObserver
import de.baumann.browser.api.net.vo.Transfer
import de.baumann.browser.base.BasePresenter
import de.baumann.browser.iview.ITransferRecordView
import de.baumann.browser.model.LicenceModel

class TransferRecordPresenter : BasePresenter<ITransferRecordView>() {
    fun transList() {
        LicenceModel().transList()
                .subscribe(object : OdinObserver<List<Transfer>>() {
                    override fun onSuccess(data: List<Transfer>?) {
                        if (view != null)
                            view.setTransferRecordData(data)
                    }
                })
    }
}